import { CooperateStatusOptions } from '@/constant/supplier'
import { useAppSelector } from '@/store/hooks'
import { ITableData } from './types'
export const useFormEdit = (): IItemArray[] => {
  return [
    {
      name: 'seasonName',
      label: '开发季',
      type: 'Input',
      placeholder: '请输入开发季',
      rules: [
        {
          required: true,
          message: '请输入开发季',
        },
      ],
    },
    {
      name: 'year',
      label: '年份',
      type: 'DatePicker',
      placeholder: '请选择年份',
      rules: [
        {
          required: true,
          message: '请选择年份',
        },
      ],
      config: {
        picker: 'year',
        format: 'YYYY',
      },
    },
  ]
}
export const useFormAddFabric = (): IItemArray[] => {
  return [
    {
      name: 'fabricTypeName',
      label: '面种名称',
      type: 'Input',
      placeholder: '请输入面种名称',
      rules: [
        {
          required: true,
          message: '请输入面种名称',
        },
      ],
    },
    {
      name: 'fabricBreadth',
      label: '幅宽（cm）',
      type: 'Input',
      placeholder: '请输入幅宽（cm）',
      rules: [
        {
          required: true,
          message: '请输入幅宽（cm）',
        },
      ],
    },
    {
      name: 'gramWeight',
      label: '克重（g/㎡）',
      type: 'Input',
      placeholder: '请输入克重（g/㎡）',
      rules: [
        {
          required: true,
          message: '请输入克重（g/㎡）',
        },
      ],
    },
    {
      name: 'yarnSpec',
      label: '纱支规格',
      type: 'TextArea',
      placeholder: '请输入纱支规格',
      rules: [
        {
          required: true,
          message: '请输入纱支规格',
        },
      ],
      config: {
        showCount: true,
        maxLength: 200,
      },
    },
    {
      name: 'fabricComposition',
      label: '成分',
      type: 'TextArea',
      placeholder: '请输入成分',
      rules: [
        {
          required: true,
          message: '请输入成分',
        },
      ],
      config: {
        showCount: true,
        maxLength: 200,
      },
    },
  ]
}
